Learn R Programming

rtfbs (version 0.3.15)

[.ms: Extract, replace, reorder MS

Description

Treat multiple sequences as a array where each row corresponds to a sequence for one species.

Usage

# S3 method for ms
[(x, rows)

Arguments

x

An object of type ms

rows

A numeric vector of sequence indices, character vector (containing sequence name), or logical vector (containing sequences to keep). If logical vector it will be recycled as necessary to the same length as nrow.ms(x).

Value

An MS object sampled from x as indicated by rows.

Details

The bracket notation can return a set of sequences, or re-order rows.